﻿
Partial Class CMiCuenta
    Inherits System.Web.UI.Page

    'instanciar clases
    Dim cliente As New ClienteDAO

    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        Master.MostrarClienteSession()
        lblClienteSession.Text = Session("cliente")
    End Sub

    Protected Sub btnActualizarCliente_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnActualizarCliente.Click
        'instanciar el objeto  dao de cliente
        Dim cli As New ClienteBE
        cli.cod_cliente = Session("cliente")
        cli.email_cliente = txtEmail.Text
        cli.password_cliente = txtPassword.Text
        cli.nom_cliente = txtNombres.Text
        cli.ape_cliente = txtApellidos.Text
        cli.direc_cliente = txtDireccion.Text
        cli.tfno_cliente = txtTelefono.Text
        cli.tipo_doc = cboTipoDoc.SelectedValue
        cli.nro_doc = txtNroDoc.Text

        'ejecutar
        cliente.Actualizar(cli)

        Response.Redirect("Home.aspx")

    End Sub
End Class
